﻿@{
    ViewBag.Title = "DropDown";
    var firstRegions = ViewBag.FirstRegions as IEnumerable<SelectListItem>;
}
<fieldset>
    <legend>Ajax DropDown</legend>
    <label class="control-label" for="firstRegion">First Region. :</label>
    @Ajax.DropDownList("firstRegion", Url.Action("GetChildRegions"), "secondRegion", firstRegions)
    <label class="control-label" for="secondRegion">Second Region. :</label>
    @Ajax.DropDownList("secondRegion", Url.Action("GetChildRegions"), "thirdRegion", new List<SelectListItem> { })
    <label class="control-label" for="secondRegion">Third Region. :</label>
    @Html.DropDownList("thirdRegion", new List<SelectListItem> { })
</fieldset>